//
// Created by Administrator on 2020/8/4.
//
#include <iostream>
#include <fstream>

int main() {

    using std::ofstream;
    using std::cin;
    using std::cout;

    using namespace std;
    char context[50];

    cin.getline(context, 50);

    cout << context << std::endl;

    ofstream outFile;

    outFile.open("outfile.txt");

    outFile << context << std::endl << context;

    outFile.close();

    return 0;
}
